#pragma warning(disable::4996)
#include<stdio.h>
#include<math.h>
int Sum(int i)
{
	int x = i % 10;
	int y = i / 10 % 10;
	int z = i / 100;
	return x * x * x + y * y * y + z * z * z;
}
int main()
{
	//100~999的水仙花数
	for (int i = 100; i <= 999; i++)
	{
		int ret = Sum(i);
		if (i == ret)
		{
			printf("%d ", i);
		}
	}
	return 0;
}